// tcpseverDlg.h : header file
//

#if !defined(AFX_TCPSEVERDLG_H__B7391159_56FC_40B1_AD6E_F7C563E48A70__INCLUDED_)
#define AFX_TCPSEVERDLG_H__B7391159_56FC_40B1_AD6E_F7C563E48A70__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

/////////////////////////////////////////////////////////////////////////////
// CTcpseverDlg dialog

class CTcpseverDlg : public CDialog
{
// Construction
public:

	void oncl();
	void onac();
	void onrev(int );
	CTcpseverDlg(CWnd* pParent = NULL);	// standard constructor
    void OnOK(){
    Onsend();
	};

// Dialog Data
	//{{AFX_DATA(CTcpseverDlg)
	enum { IDD = IDD_TCPSEVER_DIALOG };
	//}}AFX_DATA

	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CTcpseverDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:
	HICON m_hIcon;
private:

	// Generated message map functions
	//{{AFX_MSG(CTcpseverDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();

	afx_msg void OnClose();
	afx_msg void Onlisten();
	afx_msg void Onsend();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};
class csocket:public CSocket{
public:
	void OnReceive(int i){
		dlg->onrev(mynum);
	};
	void OnAccept(int i){
		dlg->onac();
		
	};
	void OnClose(int i){
		dlg->oncl();
	};
	void setp(CTcpseverDlg * severdlg,int num){
    mynum=num;
    dlg=severdlg;
	};
private:
	CTcpseverDlg *dlg;
	int mynum;
	
	
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_TCPSEVERDLG_H__B7391159_56FC_40B1_AD6E_F7C563E48A70__INCLUDED_)
